package net.alteiar.ui.editor;

import java.awt.event.MouseEvent;
import java.awt.event.MouseWheelEvent;

import net.alteiar.ui.condition.MouseCondition;
import net.alteiar.ui.editor.ImageInfoEditorPanel.EditorState;

public class EditorCondition implements MouseCondition {

	private final ImageInfoEditorPanel editor;
	private final EditorState state;

	public EditorCondition(ImageInfoEditorPanel editor, EditorState state) {
		this.editor = editor;
		this.state = state;
	}

	@Override
	public Boolean canDoAction(MouseEvent e) {
		return editor.getState().equals(state);
	}

	@Override
	public Boolean canDoAction(MouseWheelEvent e) {
		return false;
	}

}
